from selenium import webdriver

mobile_emulation = {"deviceName": "iPhone 5"}

chrome_options = webdriver.ChromeOptions()

# 传入指定参数手机型号用于
chrome_options.add_experimental_option("mobileEmulation", mobile_emulation)

driver = webdriver.Chrome(desired_capabilities = chrome_options.to_capabilities())

driver.get('http://www.baidu.com')

input('请输入。。。\n')
driver.quit()